Image processing apparatus

ABSTRACT

An image is displayed without impairing visibility, even in the case of a screen having a limited size. A display setting unit includes a target image display unit that displays an image of a workpiece on an LCD, an image selection unit that, in accordance with a selection operation, selects all or part of the image of the workpiece displayed on the LCD, a menu display unit that displays a menu image so as to be overlapped with the image of the workpiece in a translucent state, the menu image being made up of a plurality of parts that are partial images for displaying information or receiving an input operation, and a display switching unit that, in accordance with a switching instruction given via the operation unit, switches the size of the area occupied by the menu image on the LCD.

CROSS REFERENCE TO RELATED APPLICATIONS

This application claims priority based on 35 USC 119 from prior JapanesePatent Application No. 2010-088859 filed on Apr. 7, 2010, entitled“IMAGE PROCESSING APPARATUS”, the entire contents of which areincorporated herein by reference.

BACKGROUND OF THE INVENTION

1. Technical Field

The present invention relates to an image processing apparatus, and inparticular to an image processing apparatus that controls display of aprocessing target image and display of a menu related to imageprocessing functions on the same screen.

2. RELATED ART

In the field of FA (Factory Automation) and the like, a so-called visualsensor is used as an apparatus for optically detecting defects inhalf-finished products in the manufacturing process, in finishedproducts before shipping, and the like, and for optically measuring thesize of such defects.

When performing detection and measurement with a visual sensor, an imageof a workpiece (object) is captured, and inspection and measurement arecarried out by performing various types of image processing on thecaptured image. When a visual sensor is installed at an actualmanufacturing site or the like, an image processing apparatus is used toprocess the captured input image that has been output from the imagingapparatus included in the visual sensor. A user then displays the inputimage on a monitor, and sets values for various items related toinspection and measurement while checking the displayed input image. Afunction for displaying an image serving as the processing target and animage processing menu on the same screen is proposed in Patent Document1,for example.

[Related Art Documents] [Patent Documents]

[Patent Document 1] Japanese Unexamined Patent Application No.H07-160456

SUMMARY

Patent Document 1 discloses a display method for dividing a displayscreen into a work area in which the processing target image isdisplayed and a display area in which the image processing menu isdisplayed. As long as the screen is sufficiently large, the visibilityof the processing target image will not suffer even if the work area andthe image processing menu display area are displayed on the same screenat the same time.

However, the screen size is limited in the case of, for example, amobile display device to be carried around a manufacturing site or thelike, and therefore when the area for displaying the processing targetimage and the image processing menu display area are displayed on thesame screen at the same time as in Patent Document 1, the areas willinevitably be small. For this reason, the user cannot sufficiently checkthe processing target image when selecting an item from the menu whilechecking the processing target image, and thus operation of such adisplay is difficult.

An embodiment of the invention provides an image processing apparatusfor processing an image of a target object while displaying the image ofthe target object on a display unit for inspection of the target object,the image processing apparatus including: a target image display unitthat displays the image of the target object on the display unit; animage selection unit that, in accordance with a selection operation,selects all or part of the image of the target object displayed on thedisplay unit; and a menu display unit that displays a menu image so asto be overlapped with the image of the target object in a translucentstate, the menu image being made up of a plurality of parts that arepartial images for displaying information or receiving an inputoperation, wherein the menu display unit includes a display switchingunit that, in accordance with an external switching instruction,switches the menu image displayed on the display unit such that the sizeof an area occupied by the menu image on the image of the target objectis different.

Preferably, in accordance with the switching instruction, the displayswitching unit performs switching such that the number of partsdisplayed in the menu image on the display unit is different.

Preferably, in accordance with the switching instruction, the displayswitching unit switches between display and non-display for all of theparts of the menu image on the display unit.

Preferably, in accordance with the switching instruction, the displayswitching unit switches between display and non-display of the entiretyof the menu image on the display unit.

Preferably, the image processing apparatus further includes: aninstruction unit that is operated to give the switching instruction,wherein the instruction unit is fixedly displayed at a predeterminedposition on the screen of the display unit.

Preferably, the display unit and the image processing apparatus areintegrally configured so as to be portable.

According to the apparatus above, a menu image made up of a plurality ofparts that are partial images for displaying information or receiving aninput operation is displayed overlapped with the image of the targetobject in a translucent state, and switching can be performed inaccordance with an external switching instruction so as to vary the sizeof the area occupied by the menu image on the display unit. This enablesdisplaying of an image without impairing visibility even on a displayunit having a limited screen size. As a result, it is possible to easilyoperate the image processing apparatus even in the case of selecting allor part of the displayed image of the target object.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a schematic diagram showing an overall configuration of avisual sensor system according to an embodiment;

FIG. 2 is a block configuration diagram of the visual sensor systemaccording to the embodiment;

FIG. 3 is a diagram schematically showing data exchanged between adisplay setting unit and the visual sensor according to the embodiment;

FIG. 4 is a diagram showing an example of a configuration for performingimage synthesis processing according to the;

FIG. 5 is a flowchart of image processing in an adjustment modeaccording to the embodiment;

FIGS. 6A and 6B are diagrams showing examples of display screensaccording to the embodiment;

FIGS. 7A and 7B are diagrams showing examples of display screensaccording to the embodiment;

FIGS. 8A and 8B are diagrams showing examples of display screensaccording to the embodiment;

FIGS. 9A and 9B are diagrams showing examples of display screensaccording to the embodiment;

FIGS. 10A to 10C are diagrams showing examples of display screensaccording to the embodiment;

FIGS. 11A and 11B are diagrams showing examples of display screensaccording to the embodiment;

FIG. 12 is a diagram showing an example of a display screen according tothe embodiment;

FIG. 13 is a diagram illustrating how the visual sensor according to theembodiment is attached;

FIG. 14 is a diagram illustrating how a plurality of visual sensorsaccording to the embodiment are attached;

FIG. 15 is a schematic diagram showing an overall configuration of avisual sensor system according to another embodiment; and

FIG. 16 is a hardware configuration diagram of an image processingapparatus of the visual sensor system according to the other embodiment.

DETAILED DESCRIPTION

The following is a detailed description of embodiments of the presentinvention with reference to the drawings. Note that portions in thedrawings that are the same or correspond to each other have been giventhe same reference signs, and redundant descriptions thereof will not begiven.

Although an image processing apparatus is described below as a displaysetting unit integrally including a screen for display, there is nolimitation to this. The screen for display may be provided separately.Also, although the image processing apparatus is provided separatelyfrom a visual sensor having an imaging unit for obtaining an inputimage, the image processing apparatus may be built into the visualsensor.

FIG. 1 is a schematic diagram showing an overall configuration of avisual sensor system including an image processing apparatus accordingto the present embodiment. FIG. 2 shows a configuration of a displaysetting unit and a visual sensor according to the present embodiment.FIG. 3 schematically shows data exchanged between the display settingunit and the visual sensor according to the present embodiment.

As shown in FIG. 1, in visual sensor system 1 according to the presentembodiment, a visual sensor 200 and a display setting unit 201corresponding to the image processing apparatus are connected by atransmission cable 202 so as to be able to communicate with each otherin accordance with a predetermined protocol. An IO cable 203 connectsthe visual sensor 200 and a PLC (Programmable Logic Controller) 400 soas to be able to communicable with each other. The PLC 400 performsoverall control of the visual sensor system 1 by receiving signals fromanother apparatus and transmitting signals to the other apparatus.

A plurality of visual sensors 200 may be connected to the displaysetting unit 201 via transmission cable 202 and a hub (not shown). Auser can control image processing and image capture processing bytransmitting data for image processing and image capture processing tovisual sensor 200 via display setting unit 201. Display setting unit 201receives image processing results from visual sensor 200 and displaysthem.

Visual sensor 200 is powered from an external power supply (not shown)via IO cable 203.

Visual sensor system 1 is incorporated in a production line, forexample. Visual sensor system 1 executes processing such as characterrecognition and imperfection inspection (hereinafter, also referred toas “inspection processing”) based on an image obtained by imaging aninspection target (the later-described “workpiece 2”).

Visual sensor 200 includes an imaging unit 212 and a controller unit213, and imaging unit 212 has an illumination unit 211 and an imaginglens 221. A microcomputer is built into the controller unit 213. Thecasing of visual sensor 200 is provided with an attachment unit 214 forattaching visual sensor 200 to a support member (not shown).

Display setting unit 201 has an LCD (Liquid Crystal Display) touch panel204 that includes a LCD integrated with a touch panel for receivinginput of an operation instruction due to the LCD screen being touched bya finger or a special-purpose pen. Display setting unit 201 receivesimage data captured by imaging unit 212 and displays the image data onLCD touch panel 204, and also receives input of an instruction givenfrom a user operation from LCD touch panel 204, and transmits theinstruction to controller unit 213 of visual sensor 200.

Next is a description of communication data exchanged between visualsensor 200 and display setting unit 201 with reference to FIG. 3. Thecommunication data includes data that is transmitted from visual sensor200 to display setting unit 201, namely current value data 500indicating the current values of various types of parameters related toinspection processing, inspection result data 502, and an input imagethat imaging unit 212 obtains by capturing an image of the workpiece 2.The communication data also includes data transmitted from displaysetting unit 201 to visual sensor 200, namely setting value data 501that has been set for the various parameters related to inspectionprocessing.

Next is a description of the configuration of visual sensor 200 anddisplay setting unit 201 with reference to FIG. 2. Visual sensor 200includes illumination unit 211, imaging unit 212 for capturing an imageof workpiece 2, and controller unit 213. Imaging unit 212 has imaginglens 221 and camera 222.

Illumination unit 211 includes an illumination control system 223 thathas an illumination lens 224 and an LED (Light Emitting Diode) 225serving as the light source.

Controller unit 213 includes an indicator light control unit 227 thatcontrols an indicator light (not shown) such as a lamp, CPU 226 forcontrolling visual sensor 200, power supply system 228 for supplyingpower to various units, an external device communication system 229 thatis connected to transmission cable 202, an input/output system 230 forinputting and outputting data from and to an external device, and amemory 231 for storing various types of data such as current value data500 for the various parameters related to images, inspection results,and image processing.

Display setting unit 201 includes power supply unit 240 for supplyingpower to various units, operation unit 241 such as a touch panel onwhich an operation is performed to input an external instruction, LCD242, LCD control unit 243 that controls LCD 242, display image controlunit 244 that controls the display of images on LCD 242 via LCD controlunit 243, an image storage unit 245 for storing images, an image controlunit 246, and a transmission unit 247. Display setting unit 201 has amicrocomputer providing the functionality of LCD control unit 243,display image control unit 244, image control unit 246, and the like.

Transmission unit 247 is connected to transmission cable 202 andincludes a switch 248 for performing input switching. In the presentembodiment, a plurality of visual sensors 200 can be connected todisplay setting unit 201 via transmission cable 202. Transmission unit247 has a plurality of input ports for communicating with a plurality ofvisual sensors 200. Switch 248 selects one of the input ports inaccordance with a command from the microcomputer. This enables displaysetting unit 201 to communicate with visual sensor 200 that is connectedto the selected input port.

Display setting unit 201 has been made compact so as to be capable ofbeing carried by a user who patrols a manufacturing line at amanufacturing site or the like, and therefore the screen size of LCD 242has also been reduced.

LCD 242 displays images based on a control signal from LCD control unit243. Based on an image signal from display image control unit 244, LCDcontrol unit 243 generates a control signal for controlling displayprocessing performed by LCD 242, and outputs the control signal to LCD242.

Operation unit 241 includes, for example, switches provided on the outerside of the casing of display setting unit 201, and a tablet (not shown)that covers the surface of LCD 242. LCD 242 and the tablet comprise atouch panel. The user inputs various types of instructions (or commands)to display setting unit 201 via the switches and the touch panel.

Display image control unit 244 generates a synthesized image 303 basedon an instruction signal 304 from operation unit 241, an image 306 sentfrom image control unit 246, an input image 300 received from visualsensor 200 via transmission unit 247, and current value data 500, andoutputs synthesized image 303 to LCD control unit 243.

Display image control unit 244 also receives an input of values based oninstruction signal 304 from operation unit 241, and outputs the valuesto transmission unit 247 as setting value data 501. Setting value data501 are transmitted to visual sensor 200 via transmission unit 247.

Image control unit 246 stores the input image received from visualsensor 200 in image storage unit 245. Image control unit 246 also readsout the image stored in image storage unit 245, and outputs the readoutimage to display image control unit 244.

In the present embodiment, a display setting screen is displayed on LCD242 of display setting unit 201 in order to display current value data500 related to items from inspection processing and to allow the user toinput the setting value data 501. The following is a detaileddescription of a method for generating the display setting screen.

FIG. 4 shows an example of the configuration of display image controlunit 244 according to the present embodiment. As shown in FIG. 4,display image control unit 244 includes a menu image signal generationunit 251, a synthesis unit 252, and a storage unit 253.

In the present embodiment, the display setting screen is assumed to bemade up of a plurality of setting screens in a hierarchy. Menu imagesignal generation unit 251 generates menu images 302 that are used inthe setting screens. Menu images 302 are made up of a plurality of UI(User Interface) parts, which are partial images for displayinginformation such as various types of parameter values related to imageprocessing for inspection processing and for receiving a user inputoperation. The parameter values are adjustable for each image processingitem, and the UI parts include, for example, icons and checkboxes forselecting processing items whose parameter values are to be adjustedamong the image processing items, and textboxes and slide bars for theinput of parameter values. When a UI part corresponding to one of theprocessing items is designated and an operation is performed thereon,menu image 302 of the next rank in the hierarchy for setting a parametervalue for the processing item corresponding to the designated UI part isgenerated, and a synthesized image 303 generated using that menu image302 is displayed.

Menu image signal generation unit 251 generates a menu image signalbased on information 301 related to the type and location of the UI partread out from storage unit 253, instruction signal 304 output fromoperation unit 241, and current value data 500 read out from memory 231of visual sensor 200, and outputs the generated menu image 302 tosynthesis unit 252.

Synthesis unit 252 receives an input of images 300 or 306 sent in unitsof frames and menu image 302 output from menu image signal generationunit 251. Synthesis unit 252 synthesizes menu image 302 in units offrames so as to be superimposed on images 300 or 306, and outputssynthesized images 303 that have been synthesized in units of frames.Menu image 302 sent to synthesis unit 252 corresponds to an input imagereceived from visual sensor 200 that was obtained by imaging workpiece2, or a captured image of workpiece 2 that was read out from imagestorage unit 245 of image control unit 246. Note that synthesis unit 252outputs images 300 or 306 as they are if menu image 302 has not beensent. Accordingly, in this case, synthesized images 303 correspond toimages 300 or 306.

LCD control unit 243 receives an input of the synthesized image 303 fromdisplay image control unit 244, generates a control signal fordisplaying the synthesized image 303, and controls LCD 242 using thegenerated control signal. Accordingly, synthesized image 303 isdisplayed on the screen of LCD 242 while being updated in units offrame.

Here, menu image signal generation unit 251 and synthesis unit 252 ofthe present embodiment variably set parameter values indicating thetransparency of each pixel of menu image 302 when synthesis isperformed. The parameter values are, for example, α (alpha) values in ablend processing related to image transparency processing.

A pixel becomes opaque if the parameter value is set to the maximumvalue, becomes transparent if the parameter value is set to “0”, andbecomes translucent if the parameter value is set to an intermediatevalue therebetween. Since the pixels of menu image 302 to be displayedby LCD 242 are set to be translucent, menu image 302 is displayedsuperimposed on image 300 in a translucent state. Accordingly, the usercan check the current values of the various parameters related toinspection processing and set such values while checking image 300displayed under menu image 302.

Visual sensor system 1 of the present embodiment has various operatingmodes, including an adjustment mode in which the values of the variousparameters related to inspection processing are set by being adjusted,and an operation mode in which the workpieces 2 on the manufacturingline are subjected to inspection processing. Images (includingsynthesized images) are displayed by display setting unit 201 in boththe adjustment mode and the operation mode. Although a description ofimage processing in the adjustment mode is provided below, the switchingof menu images described below can be similarly applied in the operationmode as well.

FIG. 5 shows a flowchart of image processing performed by displaysetting unit 201 in the adjustment mode according to the presentembodiment. The following describes an image processing procedure of thepresent embodiment with reference to FIG. 5. Note that the image 300 maybe replaced with the image 306 in the following description.

When the adjustment mode starts, synthesized image 303 generated by menuimage 302 of the highest rank in the hierarchy, being superimposed onimage 300, is displayed on LCD 242 (step S3).

When synthesized image 303 is displayed, the user selects an item whoseparameter value is to be set by operation unit 241 (step S7). Menu imagesignal generation unit 251 receives an input of instruction signal 304corresponding to the selected item (step S9), and generates and outputsmenu image 302 of the next rank in accordance with the receivedinstruction signal 304 (step S11). Synthesis unit 252 generatessynthesized image 303 by superimposing menu image 302 of the next rankonto image 300, and outputs the synthesized image 303 (step S12).Accordingly, LCD 242 displays synthesized image 303 in accordance with acontrol signal generated by LCD control unit 243 (step S13).

The user inputs a setting value for any of the various parameters byusing operation unit 241 and a UI part in the synthesized image 303.

Instruction signal 304 related to the setting value that was input issent to menu image signal generation unit 251, and thereafter menu imagesignal generation unit 251 generates and outputs menu image 302 inaccordance with instruction signal 304. Accordingly, synthesized image303 on LCD 242 is updated to a synthesized image 303 in which a value,data, or the like is displayed in the UI part based on instructionsignal 304, and updated synthesized image 303 is displayed (step S15).Note that the setting value that was input and determined is stored assetting value data 501 in a memory area (not shown) associated with menuimage signal generation unit 251.

Menu image signal generation unit 251 determines whether instructionsignal 304 instructing a switch between menu image 302 that occupies alarge area in synthesized image 303 and menu image 302 that occupies asmall area in synthesized image 303, has been sent via operation unit241 (step S17). This switching of menu image 302 will be describedlater.

If it has been determined that instruction signal 304 for switching menuimage 302 has not been sent (NO in step S17), processing moves to thelater-described step S21, and if it has been determined that instructionsignal 304 has been sent (YES in step S17), display switching processingis performed (step S19).

Each time instruction signal 304 for switching has been sent, menu imagesignal generation unit 251 operates so as to store instruction signal304. Accordingly, in the display switching processing, it is possible todetermine, based on stored instruction signal 304, whether the occupiedarea of menu image 302 currently synthesized in synthesized image 303 islarge or small.

Using operation unit 241, the user performs a setting end operation ifthe user desires to end the setting of the parameter value using the UIpart in displayed menu image 302, or the user performs an operation forselecting an item in menu image 302. Instruction signal 304 indicatingthe operation content is output to menu image signal generation unit251.

If menu image signal generation unit 251 determines that setting is tobe ended based on instruction signal 304 (YES in step S21), menu imagesignal generation unit 251 reads out and outputs setting value data 501from the memory area. Accordingly, setting value data 501 is transmittedto visual sensor 200 via transmission unit 247 (step S25). CPU 226 ofvisual sensor 200 stores the received setting value data 501 in memory231 as the current value data 500. Thereafter, in inspection processingusing a captured image obtained by imaging unit 212, processing isexecuted using current value data 500 that was read out from memory 231.

If menu image signal generation unit 251 determines that an item wasselected based on instruction signal 304 (NO in step S21, andfurthermore YES in step S23), processing returns to step S9, andsubsequent processing is performed in a similar manner for the selecteditem.

If menu image signal generation unit 251 determines, based oninstruction signal 304, that the end of setting has not been instructed,and further an item has not been selected (NO in step S21, and NO instep S23), processing returns to step S15, and processing for inputtinga setting value in the currently displayed menu image 302 continues.

Next is a description of examples of the display image displayed on LCD242 in accordance with the above-described processing procedure shown inFIG. 5, with reference to FIGS. 6 to 12. In these drawings, it isassumed that menu image 302 is displayed synthesized with image 300,which is an enlarged image of the surface (characters) of the workpiece2.

FIGS. 6A and 6B show setting screens for setting a threshold value for agood/poor determination in inspection processing. The image 300 isdisplayed over the entirety of the screen of LCD 242, and an inspectionarea frame 402 indicating the inspection range is set to the entirety ofimage 300 by default. Also, a model area frame 401 input by the userusing operation unit 241 is displayed as a graphic in image 300. Modelarea frame 401 indicates the area of a partial image that is to serve asa reference (model) for inspection processing.

Menu image 302 displayed in FIG. 6A is made up of UI parts such ascharacter string information display units 601 and 602, common buttons701 to 703, a determine button 704, and a cancel button 705. Thecharacter string information display unit 601 is always arranged at thetop of the screen and displays information such as the content ofsetting items and the setting screen being displayed, setting values,and user guidance. The common buttons 701 to 703 are always arranged atthe bottom of the screen and are displayed for providing functionscommon to each of the menu images 302. Since the UI parts constitutingmenu image 302 are transparent images, the menu can be operated whilechecking the image 300.

Common button 701 is an example of an icon and is operated in order toinput an instruction for switching menu image 302. Common button 701 isdisplayed fixed at a predetermined position (the bottom left of thescreen in the present embodiment) in all of the screens that aredisplayed by switching, and therefore the user is not likely to losesight of common button 701 even if the screen is switched.

Common button 702 is operated in order to change how image 300 isdisplayed (e.g., enlarged or reduced). Common button 703 is operated inorder to execute screen capturing. Determine button 704 and cancelbutton 705 are displayed at the bottom of the screen and are operated inorder to determine/cancel setting value data 501 that was input via menuimage 302. If the determine operation has been performed, setting valuesthat were input via menu image 302 are determined and stored as settingvalue data 501 in the memory area associated with menu image signalgeneration unit 251, and the setting screen is changed to a higherranking screen. On the other hand, if the cancel operation has beenperformed, setting values that were input via menu image 302 arecanceled, and the setting screen is changed to a higher ranking screen.

In the display state of FIG. 6A, if common button 701 is operated, theUI parts and the like of menu image 302 are hidden except for commonbutton 701 (see FIG. 6B). At this time, model area frame 401 andinspection area frame 402 continue to be displayed. If common button 701in FIG. 6B is operated, the original UI parts of menu image 302 areagain displayed superimposed on image 300 (see FIG. 6A).

Note that UI parts 602 to 605 in FIG. 6A are display units fordisplaying threshold values (correlation values with respect to a modeland a captured image, and the type of determination) indicated bycurrent value data 500 for performing inspection processing using thepartial image (model) inside model area frame 401, and slide bars andtext boxes for the numerical input of threshold values that are operatedvia operation unit 241 for setting the correlation value.

In the present embodiment, common button 701 is displayed in synthesizedimage 303, and menu image 302 can be switched by operating common button701, and the same follows for all synthesized images 303.

As described above, switching menu image 302 enables changing the numberof UI parts in menu image 302 superimposed on image 300, that is to say,enables changing the amount of area occupied by menu image 302superimposed on image 300. Accordingly, by switching to a menu image 302that occupies less area, the user can more easily check the entire areaof image 300 and make designations.

Also, a configuration is possible in which by enlarging/reducing the UIparts in displayed menu image 302 by operating common button 701, thesize of the area occupied by menu image 302 superimposed on image 300 ischanged while maintaining the same number of displayed UI parts.

Note that the operation unit for instructing switching of menu image 302is not limited to being common button 701 that is displayed. Anoperation switch provided on the casing of display setting unit 201 orthe like may be used instead of common button 701. In this case,displaying and not displaying menu image 302 superimposed on image 300is switched in conjunction with the operation of that switch.

Also, a configuration is possible in which, when menu image 302 has beenswitched to occupy a small area, the transparency of common button 701is increased, or the position of common button 701 can be changed by aso-called drag-and-drop operation. Also, a configuration is possible inwhich common button 701 is not displayed, and switching to the screen inwhich menu image 302 is displayed is performed by so-calleddouble-tapping the touch panel made up of LCD 242 and the tablet. Thisenables the user to check the entire region of synthesized image 303 andto make designations without being hindered by common button 701.

Next is a description of editing of model area frame 401 with referenceto FIGS. 7A and 7B. FIG. 7A shows a common button 706 that is operatedin order to display various types of setting item selection buttons formodel area editing. Specific examples of the selection buttons displayedwhen common button 706 has been operated will be described later.

In the case of performing editing such as changing the size or positionof model area frame 401, editing can more easily be performed if theentirety of image 300 is displayed. In view of this, by cancelling thedisplay of the UI parts of menu image 302 (note that the common button701 remains displayed) through operation of common button 701 (see FIG.7B), model area frame 401 becomes easier to edit.

In this way, in the case of selecting part or the entirety of displayedimage 300 as an area for inspection processing (the model area or thelike), the entirety of image 300 can be checked by hiding the UI partsof menu image 302 through operation of common button 701, thusfacilitating the selection of an area. Also, since menu image 302 isdisplayed superimposed on image 300 in a translucent state, a portion ofimage 300 that is overlapped with the UI parts of menu image 302 canalso be selected as model area frame 401.

FIGS. 8A and 8B show examples of display screens for setting parametervalues related to color extraction in image processing. In the case ofcolor extraction, menu image 302 displayed superimposed on image 300includes UI parts 606 to 611 for selecting the color of an area to beextracted from image 300. Also displayed is a common button 707 that isoperated in order to instruct the end of the setting of parameter valuesrelated to color extraction.

UI part 606 shows checkboxes for selecting colors that are to beextracted. UI part 608 indicates a color palette for color selection.The color palette for color selection is provided with UI parts 610 thatcan slide in the horizontal direction of the screen and UI parts 611that can slide in the vertical direction of the screen. Sliding UI parts610 enables setting the degree of hue, and sliding UI parts 611 enablessetting the degree of saturation. Furthermore, operating UI parts 609(sliders) provided on UI part 607 (slide bar) enables setting the colorvalue.

The character string information display unit 601 displayed at the topof the screen displays values (H: hue, S: saturation, and V: value) thatare set by sliding the UI parts described above, and these values changein conjunction with the sliding.

If parameter values for color extraction are set via the UI parts ofmenu image 302, the set values are read out by display image controlunit 244 as UI setting values 305. Image control unit 244 extracts areasincluding the designated colors indicated by UI setting values 305 fromimage 300, and generates an image 306 in which only the extracted colorarea portions remain. The generated image 306 is sent to synthesis unit252 in place of image 300.

Accordingly, since menu image 302 is displayed superimposed on image 306obtained using the parameter values set via the UI parts, the user canset parameter values as well as check the result of image processingperformed using the set parameter values.

At this time, by cancelling the display of the UI parts of menu image302 (note that the common button 701 remains displayed) throughoperation of common button 701 (see FIG. 8B), the entirety of image 306resulting from image processing can be checked.

FIGS. 9 to 12 show other screens displayed in the adjustment mode. Sincecommon button 701 is displayed in these screens as well, menu image 302can be easily switched between occupying a large area and occupying asmall area.

FIG. 9A shows a high ranking menu image 302 in the adjustment mode. InFIG. 9A, UI part 612 at the left end of menu image 302 shows an itemmenu showing functions of display setting unit 201. In FIG. 9A, if“Imaging” in the operation item menu has been selected, selectionbuttons for “Camera adjustment”, “Trigger adjustment”, and “Alignmentcorrection”, which are setting items for imaging, are displayed on theright side of the screen in the order in which setting needs to beperformed.

FIG. 9B shows an example of a display in the case where “Inspection” inthe operation item menu of UI part 612 has been selected, in which alist of functions used for inspection are displayed on the right side ofthe screen in a menu format.

If “Camera adjustment” has been selected in the setting item menudisplayed on the right side of the screen in FIG. 9A, menu image 302shown in FIG. 10A is displayed. UI part 614 in FIG. 10A is fordisplaying a number indicating the focus value in image 300 (in FIG.10A, the value 85), and a corresponding bar graph. The focus value showsthe degree to which the focal point of imaging unit 212 coincides withthe imaging subject such as a workpiece, and the focus value changes inconjunction with focus adjustment operations performed by visual sensor200. Note that since the focus value correlates with the quantity ofedges that appear in the input image, the focus value can be calculatedbased on, for example, color deviation included in the input image.

FIG. 10B shows an example of menu image 302 displayed if “Alignmentcorrection” has been selected in the subordinate function menu shown inFIG. 9A. In FIG. 10B, character string information display unit 601shows whether processing for correcting the alignment of imaging unit212 is selected, and the fact that it is the alignment correctionsetting.

If “Alignment correction setting” was selected in FIG. 10B, menu image302 shown in FIG. 10C is displayed. In FIG. 10C, UI part 709 forselecting the execution of teach processing for alignment correction isdisplayed. In teach processing, processing for registering model areaframe 401 and inspection area frame 402 that have been set is performed(i.e., processing for storage in a predetermined storage area of displaysetting unit 201, or processing for transmission to visual sensor 200and storage in a predetermined storage area).

If common button 706 in FIG. 10C is operated, a setting item selectionbutton 7061 is displayed as shown in FIG. 11A. Here, if “Edit modelarea” is selected, menu image 302 shown in FIG. 11B is displayed, andthe model area to be used in alignment correction processing can be set.The model area frames 401 and 405 have been set in FIG. 11B. Theposition and size of the set model area is detected and displayed incharacter string information display unit 601. Also, the position andsize of model area frame 401 and 405 on image 300 can be changed byoperating the UI part 613.

FIG. 12 shows an example of menu image 302 displayed if “Edge position”was selected in the function menu shown in FIG. 9B.

An image edge level is set in the screen shown in FIG. 12. UI parts 614and 615 for setting the level according to which edges are to beextracted from image 300, as well as an edge graphic 403 are displayedin FIG. 12. In edge graphic 403, the edge level in inspection area frame402 is detected, position in image 300 is plotted on the horizontal axisof the graph, and edge level is plotted on the vertical axis.

Edge graphic 403 is generated by image control unit 246 performing edgedetection based on the brightness component level of each pixel in image300. The generated edge graphic 403 is displayed superimposed on image300.

UI part 615 (slider) is displayed in association with edge graphic 403.By operating the slider, the user can determine a desired edge levelthreshold value while referencing edge graphic 403. Note that thedetected edge position is shown by a cross mark 404.

While the slide operation is performed, the set threshold value isnumerically displayed in the numerical value input box of UI part 614while being sequentially updated in conjunction with the slideoperation.

In the above-described screens of FIGS. 9 to 12 as well, the entirety ofimage 300 targeted for processing is displayed, and menu image 302including translucent UI parts is displayed superimposed on image 300,and in such a screen, switching of the UI parts of menu image 302 can beperformed by operating common button 701.

FIG. 13 shows an example of how visual sensor 200 is attached. FIG. 14shows a state in which visual sensors 200 are respectively attached toconveying lines of belt conveyors or the like, which are a plurality ofconveying mechanisms 6 (the arrow in the figure indicates the conveyingdirection), as viewed from above the conveying lines. In FIG. 13, visualsensor 200 corresponding to each line is attached to a support member(not shown) via attachment unit 214 such that the imaging range ofcamera 222 is aligned with the conveying line. When imaging isperformed, illumination light is irradiated on the conveying line ofconveying mechanism 6, thus providing illumination in the imaging range.Visual sensors 200 provided for the conveying lines exchange inspectionprocessing result information, information for inspection processingincluding the current value data 500, and the like with each other viatransmission cable 202.

OTHER EMBODIMENTS

Although the imaging function and the image processing function forinspection processing are provided integrally in visual sensor 200 inthe above-described embodiment, these functions may be providedseparately and independently as shown in the present embodiment.

As shown in FIG. 15, in a visual sensor system 1 according to anotherembodiment that is incorporated in an FA production/manufacturing lineor the like, workpieces 2 that are objects to be subjected tomeasurement are conveyed in the arrow direction in FIG. 15 by aconveying mechanism 6 such as a belt conveyor, and the workpieces 2 aresuccessively imaged by an imaging apparatus 8 in order to performinspection processing on the workpieces 2. Image data obtained byimaging apparatus 8 (hereinafter, also referred to as “input images”)are transmitted to an image processing apparatus 100. Note that it ispossible to further provide an illumination mechanism that emits lightonto the workpieces 2 that are imaged by imaging apparatus 8.

A photoelectric sensor 4 made up of two parts disposed on respectivesides of conveying mechanism 6 detects the fact that a workpiece 2 hasarrived in the imaging range of the imaging apparatus 8. Specifically,photoelectric sensor 4 includes a photoreception unit 4 a and aphotoemission unit 4 b disposed on the same optical axis. Thephotoreception unit 4 a detects the fact that light emitted from thephotoemission unit 4 b is blocked by workpiece 2, thus detecting thearrival of workpiece 2. A detection signal (hereinafter, also referredto as a “trigger signal”) from photoelectric sensor 4 is output to a PLC5.

PLC 5 receives the trigger signal from photoelectric sensor 4 or thelike, and performs control of the conveying mechanism 6.

Visual sensor system 1 in FIG. 15 further includes image processingapparatus 100, a display 102, and a keyboard 104. Image processingapparatus 100 is connected to PLC 5, imaging apparatus 8, display 102,and keyboard 104.

Image processing apparatus 100 has various types of operating modes,namely an operation mode for executing inspection processing on theworkpieces 2, and the above-described adjustment mode. In the operationmode, image processing apparatus 100 gives an imaging command to imagingapparatus 8 upon receiving the trigger signal from photoelectric sensor4 via PLC 5. In response to the imaging command, imaging apparatus 8transmits an input image obtained by capturing an image of the workpiece2 to image processing apparatus 100. As an alternative processingmethod, a configuration is possible in which imaging apparatus 8 iscaused to continuously perform imaging, and image processing apparatus100 obtains only necessary input images in response to receiving thetrigger signal.

Imaging apparatus 8 includes, for example, an optical system such as alens, and an imaging element partitioned into a plurality of pixels,such as a CCD (Charged Coupled Device) or a CMOS (Complementary MetalOxide Semiconductor) sensor. Imaging apparatus 8 is assumed to beattached such that its installation location, which determines theimaging range, can be changed manually.

Image processing apparatus 100 is a computer having a general-purposearchitecture, and provides various types of functions by executing apre-installed program.

FIG. 16 is a schematic configuration diagram showing image processingapparatus 100 according to this other. As shown in FIG. 16, imageprocessing apparatus 100 includes a CPU 110, which is an arithmeticprocessing unit, a memory 112 and a hard disk 114, which are storageunits, a camera interface 116, an input interface 118, a displaycontroller 120, a PLC interface 122, a communication interface 124, anda data reader/writer 126. These units are connected via a bus 128 suchthat data can be exchanged therebetween.

CPU 110 performs various types of computation for processing in theoperation mode and the above-described adjustment mode by deployingprograms (code) stored in hard disk 114 to memory 112 and executing theprograms in a predetermined sequence.

Camera interface 116 mediates the transmission of data between the CPU110 and imaging apparatus 8. More specifically, camera interface 116includes an image buffer 116 a that can be connected to one or moreimaging apparatuses 8 and temporarily accumulates image data fromimaging apparatuses 8. When at least one frame of input image data hasbeen accumulated in image buffer 116 a, camera interface 116 transfersthe accumulated data to memory 112.

Memory 112 stores image data in units of image files. In the case ofperforming processing on an input image, CPU 110 reads out an image filefrom memory 112.

Camera interface 116 gives an imaging command to imaging apparatus 8 inaccordance with an internal command issued by CPU 110.

Input interface 118 mediates the transmission of data between CPU 110and input apparatuses such as keyboard 104, a mouse 103, and a touchpanel (not shown). Specifically, input interface 118 receives anoperation command given by the user operating an input apparatus.

Display controller 120 is connected to the display 102, which is atypical example of a display apparatus, and notifies the user of, forexample, results of image processing performed by CPU 110.

PLC interface 122 mediates the transmission of data between CPU 110 andPLC 5. More specifically, PLC interface 122 transmits, to CPU 110,information regarding the state of the production line controlled by PLC5, information regarding the workpiece, and the like.

Communication interface 124 mediates the transmission of data betweenCPU 110 and another personal computer, a server apparatus, or the like,which are not shown. Communication interface 124 is typically anEthernet (registered trademark) interface, a USB (Universal Serial Bus)interface, or the like. Note that as will be described later, as analternative to the embodiment in which a program stored on memory card106 is installed in image processing apparatus 100, an embodiment ispossible in which a program downloaded from a distribution server (notshown) or the like via communication interface 124 is installed in imageprocessing apparatus 100.

Data reader/writer 126 mediates transmission of data between CPU 110 andmemory card 106, which is a storage medium.

In visual sensor system 1 shown in FIGS. 15 and 16, display 102corresponds to LCD 242 in FIG. 2, and the above-described functions ofdisplay setting unit 201 in the adjustment mode are executed based oncontrol performed by CPU 110 of image processing apparatus 100.Accordingly, even with the configuration shown in FIGS. 15 and 16,parameter values for inspection processing can be set while menu image302 is displayed superimposed on processing target image 300 in atranslucent state, and menu image 302 can be switched by operatingcommon button 701. This enables more easy operation with respect to thesetting of parameter values while checking image 300.

In this way, as explained above, the embodiments provides imageprocessing apparatus that can display an image without impairingvisibility, even in the case of a screen having a limited size.

The embodiments disclosed in this application are to be considered inall respects as illustrative and not limiting. The scope of theinvention is indicated by the appended claims rather than by theforegoing description, and all changes which come within the meaning andrange of equivalency of the claims are intended to be embraced therein.

1. An image processing apparatus for processing an image of a targetobject while displaying the image of the target object on a display unitfor inspection of the target object, the image processing apparatuscomprising: a target image display unit that displays the image of thetarget object on the display unit; an image selection unit that, inaccordance with a selection operation, selects all or part of the imageof the target object displayed on the display unit; and a menu displayunit that displays a menu image so as to be overlapped with the image ofthe target object in a translucent state, the menu image being made upof a plurality of parts that are partial images for displayinginformation or receiving an input operation, wherein the menu displayunit includes a display switching unit that, in accordance with anexternal switching instruction, switches the menu image displayed on thedisplay unit such that the size of an area occupied by the menu image onthe image of the target object is different.
 2. The image processingapparatus according to claim 1, wherein in accordance with the switchinginstruction, the display switching unit performs switching such that thenumber of parts displayed in the menu image on the display unit isdifferent.
 3. The image processing apparatus according to claim 2,wherein in accordance with the switching instruction, the displayswitching unit switches between display and non-display for all of theparts of the menu image on the display unit.
 4. The image processingapparatus according to claim 2, wherein in accordance with the switchinginstruction, the display switching unit switches between display andnon-display of the entirety of the menu image on the display unit. 5.The image processing apparatus according to claim 1, further comprising:an instruction unit that is operated in order to give the switchinginstruction, wherein the instruction unit is fixedly displayed at apredetermined position in a screen of the display unit.
 6. The imageprocessing apparatus according to claim 1, wherein the image selectionunit can select a portion of the image of the target object that isoverlapped with any of the plurality of parts as well.
 7. The imageprocessing apparatus according to claim 1, wherein the display unit andthe image processing apparatus are integrally configured so as to beportable.